/**@file
 * @brief Solution类声明
 * @author <libxiangnan@gmail.com>
 * @date 2011/11/24
 * @version 0.0.1
 * */

#ifndef SOLUTION_H_
#define SOLUTION_H_

#include <vector>
#include <string>

#include "entity.h"
#include "suite.h"

using namespace std;

namespace dat {

/**@class Solution solution.h solution.h
 * @brief 测试Solution声明
 * @author 朱项男<libxiangnan@gmail.com>
 * */
class Solution: public dat::Entity {
private:
	std::vector<Solution>solutions;		///< Solution具有递归特性
	std::vector<Suite> suites;			///< Suite堆栈
public:
	//! @brief 构造函数
	Solution();

	//! @brief 析构函数
	~Solution();

	//! @brief 添加下一级Solution
	void add(const Solution &solution);

	//! @brief 添加下一级Suite
	void add(const Suite &suite);

	//! @brief solutions Setter
	void setSolutions(const std::vector<Solution> &solutions);

	//! @brief solutions Getter
	std::vector<Solution> getSolutions();

	//! @brief suites Setter
	void setSuites(const std::vector<Suite> &suites);

	//! @brief suites Getter
	std::vector<Suite> getSuits();

	//! @brief 根据ID移除下一级Solution/Suit
	bool rmById(const std::string &id);

	//! @brief 清空下一级Solutions
	void emptySolutions();

	//! @brief 清空下一级Suites
	void emptySuites();

	//! @brief 清空下一级
	void emptyAll();

};

} /* namespace dat */
#endif /* SOLUTION_H_ */
